#!/bin/bash
name=Mafuraha-Maneno.jar

if [ -z "$1" ]; then
    echo "running..."
    java -jar $name &
fi

for a in $@
do
 
if [ "$a" == "make" ]; then
    javac -cp \*  src/*.java
    mv src/*.class .
    jar cfm $name manifest *.class imgs/*.JPG users.db USER_GUIDE.txt
    mv *.class bin/

elif [ "$a" == "run" ]; then
    echo "running..."
    java -jar $name &

else
    echo "Commands: "
    echo "make"
    echo "run"
    echo "make run"
fi

done
